package com.icongyou.enterprise.talent_marking.mapper;

import com.icongyou.enterprise.talent_marking.entity.StudentPerformanceSnapshots;
import org.apache.ibatis.annotations.Param;

import java.time.LocalDate;
import java.util.List;

public interface StudentPerformanceTrackingServiceMapper {

    //判断某学生某课程某日期的快照是否存在
    boolean existsSnapshot(@Param("studentId") String studentId,
                           @Param("courseId") String courseId,
                           @Param("snapshotDate") LocalDate snapshotDate);

    //插入学生表现快照
    void insert(StudentPerformanceSnapshots snapshot);

    //根据学生id、课程id和日期查询学生表现快照
    StudentPerformanceSnapshots selectByStudentAndCourseAndDate(@Param("studentId") String studentId,
                                                                @Param("courseId") String courseId,
                                                                @Param("lastWeek") LocalDate lastWeek);

    //查询所有被关注的学生id列表
    List<String> selectAllActiveStudentIds();
}
